Data in computer files is frequently organized into rows and columns. Because computer files are just one long continuous string of bytes, the data is separated by row and column delimiters, which are typically different from one another, to indicate breaks between columns and rows. Thus, a comma separated file will use commas between the columns of each row, and a different delimiter between the rows. Between the delimiters are the data in the file.
Some data itself may use the delimiter characters for purposes other than to delimit a new column or row. To allow data to use the delimiter characters for other purposes, a set of string delimiters is used to indicate that, between the string delimiters, characters that correspond to row or column delimiters are not being used as delimiters, but are part of the data in the file. String delimiters are typically used in pairs, with a starting delimiter and an ending delimiter such as [this string] with brackets used as the delimiter. The starting and ending delimiters may be different or may be the same, such as ‘this string’ which uses single quotes for both delimiters.
Because different files may have different delimiters, to allow a program to use files from many sources of which the delimiters may be different and unknown, it can be helpful to identify the delimiters being used by a particular file. What is needed is a system and method that can automatically identify delimiters in a file.